/**
  ******************************************************************************
  * @file    DCDC_type.h
  * @author  STMicroelectronics
  * @version 1.1.0
  * @date    31-Mar-2022
  * @brief   This file contains type definitions for DCDC control
  ******************************************************************************
  *
  * Copyright (c) 2014(-2022) STMicroelectronics.
  * All rights reserved.
  *
  * This software is licensed under terms that can be found in the LICENSE file in
  * the root directory of this software component.
  * If no LICENSE file comes with this software, it is provided AS-IS.
  ******************************************************************************
  *
  */
/* Define to prevent recursive inclusion -------------------------------------*/
#ifndef __DCDC_TYPE_H
#define __DCDC_TYPE_H

#ifdef __cplusplus
extern "C" {
#endif

/* Includes ------------------------------------------------------------------*/
/* Private includes ----------------------------------------------------------*/
#include "dpwr.h"
#include "dpwr_dcdc.h"
#include "stm32g4xx_hal.h"

/* Exported types ------------------------------------------------------------*/
/**
* @brief  Acquisition struct type definition
*/
typedef struct
{
int16_t hVout;              // ADCx 1st regular acquisition
int16_t hIout;              // ADCx 1st regular acquisition
uint16_t hTemperature;       // ADCy 1st regular acquisition
uint16_t hVdsSRRising_x1;    // ADCx 1st injected acquisition for SR1 signal
uint16_t hVdsSRRising_y1;    // ADCy 1st injected acquisition for SR1 signal
uint16_t hVdsSRFalling_x1;   // ADCx 2nd injected acquisition for SR1 signal
uint16_t hVdsSRFalling_y1;   // ADCy 2nd injected acquisition for SR1 signal
uint16_t hVdsSRRising_x2;    // ADCx 3rd injected acquisition for SR2 signal
uint16_t hVdsSRRising_y2;    // ADCy 3rd injected acquisition for SR2 signal
uint16_t hVdsSRFalling_x2;   // ADCx 4th injected acquisition for SR2 signal
uint16_t hVdsSRFalling_y2;   // ADCy 4th injected acquisition for SR2 signal
uint16_t hViperVoltage;      // ADCy 2nd regular acquisition - NOT USED
} DCDC_MeasureStruct_t;

/* Exported macro ------------------------------------------------------------*/
/* Exported constants --------------------------------------------------------*/
/* Private defines -----------------------------------------------------------*/
/* Exported functions prototypes ---------------------------------------------*/

#ifdef __cplusplus
}
#endif

#endif /* __DCDC_TYPE_H */
